[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
select(FILEHANDLE)
select
Returns the currently selected filehandle. Sets the
current default filehandle for output, if FILEHANDLE
is supplied. This has two effects: first, a write
or a print without a filehandle will default to this
FILEHANDLE. Second, references to variables related
to output will refer to this output channel. For
example, if you have to set the top of form format
for more than one output channel, you might do the
following:
select(REPORT1);
$^ = 'report1_top';
select(REPORT2);
$^ = 'report2_top';
FILEHANDLE may be an expression whose value gives
the name of the actual filehandle. Thus:
$oldfh = select(STDERR); $| = 1; select($oldfh);
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson